Connect My Computer: Store agent logs#32044
Merged
Conversation
1b0f8fd to
33b9492
Compare
ravicious
reviewed
Sep 20, 2023
Member
ravicious
left a comment
There was a problem hiding this comment.
Thanks for adding those extra "Open logs" buttons!
This reverts commit 3475be8.
043901d to
e9e8902
Compare
ravicious
approved these changes
Sep 21, 2023
avatus
approved these changes
Sep 21, 2023
# Conflicts: # web/packages/teleterm/src/mainProcess/mainProcess.ts # web/packages/teleterm/src/mainProcess/mainProcessClient.ts # web/packages/teleterm/src/ui/ConnectMyComputer/DocumentConnectMyComputerStatus/DocumentConnectMyComputerStatus.tsx
gzdunek
added a commit
that referenced
this pull request
Sep 25, 2023
* Add `omitTimestamp` to `FileLoggerOptions` * Store logs of the agent process * Kill agent process with SIGQUIT SIGQUIT is used for a graceful shutdown https://github.com/gravitational/teleport/blob/1212306cff9be443286cdf0e8cbdf6471fc392d7/lib/service/signals.go#L59 * Add menu item that opens logs directory * Add an action that opens agent logs directory * Revert "Kill agent process with SIGQUIT" This reverts commit 3475be8. * Change 'Learn More' to 'Open Documentation' * Add a note to the notification that the logs dir may not exist (cherry picked from commit d56beee)
github-merge-queue Bot
pushed a commit
that referenced
this pull request
Sep 25, 2023
* Add `omitTimestamp` to `FileLoggerOptions` * Store logs of the agent process * Kill agent process with SIGQUIT SIGQUIT is used for a graceful shutdown https://github.com/gravitational/teleport/blob/1212306cff9be443286cdf0e8cbdf6471fc392d7/lib/service/signals.go#L59 * Add menu item that opens logs directory * Add an action that opens agent logs directory * Revert "Kill agent process with SIGQUIT" This reverts commit 3475be8. * Change 'Learn More' to 'Open Documentation' * Add a note to the notification that the logs dir may not exist (cherry picked from commit d56beee)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contributes to #27881
Adds storing agent logs to disk.
Teleport has an ability to store logs, but unfortunately it is disabled by default and the only way to enable it (and set a path) is by modyfying the config.yaml file. For now, we are going to take the easier way and just log on the JS side.
Logs are stored in
App Data/Teleport Connect/agents/<profile name>/logs/teleport.log.I also added a menu item to open logs dir and an action to open agent logs dir in the CMC status page.
Best to review commit-by-commit.